package Operation;

import java2021_9_23.Book;
import java2021_9_23.BookDao;

import java.util.List;

public class DisplayOperation implements IOperation{
    @Override
    public void work() {
        System.out.println("查看所有书籍");
        BookDao bookDao = new BookDao();
        List<Book> books = bookDao.selectAll();
        for(Book book:books){
            System.out.println(book);
        }
        System.out.println("所有书籍查询完毕!");
    }
}
